package com.example.springboot.service;

import com.example.springboot.Mapper.StockMapper;
import com.example.springboot.pojo.Stock;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class StockService implements StockMapper{
    @Autowired
    StockMapper stockMapper;

    @Override
    public int addStock(Stock stock) {
        return stockMapper.addStock(stock);
    }

    @Override
    public List<Stock> getStock() {
        return stockMapper.getStock();
    }

    @Override
    public int sumBook() {
        return stockMapper.sumBook();
    }
}
